import request from '@/request'
import {C2B} from '@/utils/wordtransfer.js'

// 查询搜索并分页
export const findPages = (data) => {
    return request.post("/note/comment/list",data)
}

// id删除
export const removeById = (id) => {
    return request.post(`/note/comment/remove/${id}`,{})
}

// 修改状态
export const updateStatus = (id,field,value) => {
    field = C2B(field)
    return request.post(`/note/comment/status/${id}/${field}?value=${value}`,{})
}


// 批量彻底删除
export const batchRemoves = (ids,opids) => {
    return request.post("/note/comment/batch/remove",{ids,opids})
}

// 批量上架
export const batchUps = (ids,opids) => {
    return request.post("/note/comment/batch/up",{ids,opids})
}

// 批量下架
export const batchDowns = (ids,opids) => {
    return request.post("/note/comment/batch/down",{ids,opids})
}